package com.bbzn.user.client.service;

import java.util.List;

import com.bbzn.user.client.dataobject.Permission;
import com.bbzn.user.client.dto.permission.PermissionDTO;

public interface PermissionService {


    int deleteByPrimaryKey(Long id);

    int insert(Permission record);

    int insertOrUpdate(Permission record);

    int insertOrUpdateSelective(Permission record);

    int insertSelective(Permission record);

    Permission selectByPrimaryKey(Long id);

    int updateByPrimaryKeySelective(Permission record);

    int updateByPrimaryKey(Permission record);

    List<Permission> findByAll(Permission permission);

    List<Permission> getNavigationBar(Long id);

    int updateBatch(List<Permission> list);

    int updateBatchSelective(List<Permission> list);

    int batchInsert(List<Permission> list);

    List<Permission> selectByUserId(Long userId);

    List<PermissionDTO> selectTreeByUserId(Long userId);

    List<PermissionDTO> getRolePermission(int roleId, Long userId);

    int getMaxSort();

    /**
     * 批量删除
     *
     * @param ids
     * @return
     */
    int batchDelete(List<Long> ids);

    List<Long> getPermissions();

}


